
i=0
d_x=1;
d_y=1;
dd=1;
alpha=0
delta=270;
global.bin=1;
while (global.bin>0)
{
i++;
dd=round(((alpha+delta) / 360)+1)*5;
alpha+=delta/dd;


global.d_x=dd*sin(alpha/57.3);
global.d_y=dd*cos(alpha/57.3);
xxx=mouse_x+global.d_x;
yyy=mouse_y+global.d_y;
global.xx=xxx;
global.yy=yyy;

with (player)
{global.bin=instance_place(global.xx,global.yy,obstacle);}
if ((xxx<play_map.x1+player.sprite_width/2)||(xxx>play_map.x2-player.sprite_width/2)||(yyy<play_map.y1+player.sprite_width/2)||(yyy>play_map.y2-player.sprite_width/2)) global.bin=1; 
// найдем дистанцию пробега для текущей точки
//dist=sqrt(sqr(xxx-))
//if ()

}
r=ds_list_create();
ds_list_add(r,xxx);
ds_list_add(r,yyy);

return r;



